﻿create proc thuan_qtdanhmucloaimenusua
@ID int,
@DienGiai nvarchar(255)
as
if exists(select * from DanhMuc_LoaiMenu Where MaLoaiMenu<>@ID and DienGiai=@DienGiai)
begin
select ErrCode=0
end
else
begin
update DanhMuc_LoaiMenu set DienGiai=@DienGiai WHere MaLoaiMenu=@ID
select ErrCode=1
end